package com.imusic;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.netflix.eureka.EnableEurekaClient;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
@SpringBootApplication
@EnableEurekaClient
@RestController
public class ProductApplication {
	
	private static final Logger log=LoggerFactory.getLogger(ProductApplication.class);

	public static void main(String[] args) throws Exception {
		SpringApplication.run(ProductApplication.class, args);
	
	}
	
	@RequestMapping("/getProduct")
    public String getProduct() throws InterruptedException {
        Thread.sleep(2000);
        log.info("Hello Product Microservice");
        return "Get Product Infomation from Product Microservice";
    }
	
	
}